package hu.bme.mit.inf.expendables.entities;
	
import javax.persistence.*;
import hu.bme.mit.inf.expendables.entities.*;
import java.util.List;
import java.util.ArrayList;


@Entity
@Table(name="T_DEVELOPER")
@NamedQueries(
	{
	@NamedQuery(name=Developer.GET_DEVELOPER,query="SELECT d FROM Developer d WHERE d.userId = :devId"),
	@NamedQuery(name=Developer.DELETE_DEVELOPER,query="DELETE FROM Developer d WHERE d.userId = :devId")
	})
public class Developer extends User {
	                        	
	public static final String GET_DEVELOPER = "GetDeveloper";
	public static final String DELETE_DEVELOPER = "DeleteDeveloper";

	//Attributes

	//Reference to AppMetadata
	@OneToMany(mappedBy="developer")
	private List<AppMetadata> uploadedApps= new ArrayList<AppMetadata>();
	


	//Getters and Setters

	public List<AppMetadata> getUploadedApps(){
		return uploadedApps;
	}
	
	public void setUploadedApps(List<AppMetadata> uploadedApps){
		this.uploadedApps = uploadedApps;
	}
		
}